package com.xpffly.design.adapter.demo.service.impl;

import com.xpffly.design.adapter.demo.service.IUserInfo;

import java.util.Map;

/**
 * @Author: xpengfei
 * @Date: 2021/4/12 21:06
 * @Description：外包同事的中转角色
 */
public class OuterUserInfo extends OuterUser implements IUserInfo {

    private Map<String, String> baseInfo = super.getUserBaseInfo();
    private Map<String, String> homeInfo = super.getUserHomeInfo();
    private Map<String, String> officeInfo = super.getUserOfficeInfo();


    /**
     * 获取用户姓名
     *
     * @return
     */
    public String getUserName() {
        return baseInfo.get("userName");
    }

    /**
     * 获取用户家庭地址
     *
     * @return
     */
    public String getUserHomeAddress() {
        return homeInfo.get("homeAddress");
    }

    /**
     * 获取用户电话号码
     *
     * @return
     */
    public String getUserMobileNumber() {
        return baseInfo.get("mobileNumber");
    }

    /**
     * 获取用户办公电话
     *
     * @return
     */
    public String getUserOfficeTelNumber() {
        return officeInfo.get("officeTelNumber");
    }

    /**
     * 获取用户的职位
     *
     * @return
     */
    public String getUserJobPosition() {
        return officeInfo.get("jobPosition");
    }

    /**
     * 获取用户的家庭电话
     *
     * @return
     */
    public String getUserHomeTelNumber() {
        return homeInfo.get("homeTelNumber");
    }
}
